package com.mhuang.module.wechat.service.impl;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.mhuang.module.wechat.service.SubscribeService;
import com.mhuang.wechat.common.pool.service.ExecuteService;

@Service("executorService")
public class ExecutorServiceImpl implements ExecuteService{

	private Logger logger = LoggerFactory.getLogger(getClass());
	
	@Autowired
	private SubscribeService subscribeService;
	
	@Override
	public void share(String usrId, String status, String type, String shareName, String uuid) {
		
	}

	@Override
	public void subscribe(String openId, String status) {
		logger.info("正在处理关注数据!");
		subscribeService.subscribe(openId, status);
		logger.info("关注数据处理完成。");
	}

	@Override
	public void saveOpTextSend(String openId, String content) {
		
	}

    @Override
    public void subscribeOtherEvent(String openId,String status, String eventKey) {
        logger.info("正在处理关注数据!带eventKey:"+eventKey);
        subscribeService.subscribeOtherEvent(openId,status, eventKey);
        logger.info("关注数据处理完成。");
    }

	@Override
	public void scan(String openId, String eventKey) {
		logger.info("处理扫码数据!带eventKey:"+eventKey);
		subscribeService.scan(openId, eventKey);
		logger.info("扫码数据处理完成。");
	}
}
